<template>
  <div class="dashboard-container">
    <div class="contents">
      <div class="left_cage">
        <div class="chart-item">
          <AnnualPieChart />
        </div>
        <div class="chart-item userTableContent">
          <EnterpriseUser />
          <!-- <MonthlyStartEndBar /> -->
        </div>
      </div>
      <div class="center_cage">
        <div class="chart-item mapContent">
          <Map />
        </div>
        <div class="chart-item rentTableContent">
          <payexpire />
        </div>
      </div>
      <div class="right_cage">
        <div class="chart-item">
          <AnnualStartEnd />
        </div>
        <div class="chart-item">
          <MonthlyStartEnd />
        </div>
      </div>
    </div>
  </div>
</template>

<script lang="ts" setup>
import AnnualPieChart from './components/AnnualPieChart.vue'
import AnnualStartEnd from './components/AnnualStartEnd.vue'
// import MonthlyStartEndBar from './components/MonthlyStartEndBar.vue'
import EnterpriseUser from './components/EnterpriseUser.vue'
import MonthlyStartEnd from './components/MonthlyStartEnd.vue'
import payexpire from './components/payexpire.vue'
import Map from '@/views/zszx/arcgis/Map.vue'
</script>

<style scoped>
.dashboard-container {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  height: calc(100vh - 85px);

  /* padding: 2px; */
  background-image: url('@/assets/imgs/bk.jpg');
  background-position: center;
  background-size: cover;
  box-sizing: border-box;

  /* justify-content: space-between; */
}

.contents {
  display: flex;
  width: 100%;
  height: 100%;
}

.left_cage,
.right_cage {
  display: flex;
  width: 22%;
  height: 100%;
  flex-direction: column;
}

.center_cage {
  display: flex;
  width: 56%;
  height: 100%;
  margin: 0 1px;
  flex-direction: column;
}

.chart-item {
  width: 100%;
  height: 50%;
  margin-bottom: 1px;
  border: 1px #0174f5 solid;
  border-radius: 10px;
  box-sizing: border-box;
}

.mapContent {
  position: relative;
  height: 60%;
  overflow: hidden; /* 地图不需要滚动条 */
}

.rentTableContent {
  height: 40%;
  overflow-y: auto; /* 添加垂直滚动条 */
}

.userTableContent { 
    height: 50%;
  overflow-y: auto; /* 添加垂直滚动条 */
}
</style>
